import React, { useContext } from 'react'
import {userContext} from '../../views/user/index'
import './index.scss'
interface DataType{
    id:number;
    name:string;
    phone:string;
    aveter:string;

}
const Display:React.FC<DataType> = (props)=>{
    const value=useContext(userContext);
    console.log(value)
    return <table border={1} cellSpacing="1">
        <thead>
            <tr><th colSpan={2}>{props.name}</th></tr>
        </thead>
        <tbody>
        <tr>
            <td>{props.phone}</td>
            <td><img src={props.aveter} alt="图片已被清理"/></td>
        </tr>
        </tbody>
        
    </table>
}
export default Display